package org.iteam.mina;

import java.nio.charset.Charset;

public interface Constant {
	/** 心跳 */
	final String KEEP_ALIVE_LOG_NAME = "KEEP-ALIVE";
	/** mina */
	final String MINA_LOG_NAME = "MINA";

	/** 15秒发送一次心跳包 */
	final int KEEP_ALIVE_SERVER_INTERVAL = 20;// in seconds
	/** 10秒心跳包超时时间 */
	final int KEEP_ALIVE_SERVER_TIMEOUT = 10; // in seconds
	/** 15秒发送一次心跳包 */
	final int KEEP_ALIVE_CLIENT_INTERVAL = 30;// in seconds
	/** 10秒心跳包超时时间 */
	final int KEEP_ALIVE_CLIENT_TIMEOUT = 10; // in seconds

	/** 30秒后超时 */
	final int IDEL_TIMEOUT = 30;
	/** 连接超时时间 单位：毫秒 */
	final int CONNECT_TIMEOUT_MILLIS = 5 * 1000;
	/** 发送缓冲区10M */
	final int READ_BUFFER_SIZE = 2048 * 5000;
	/** 接收缓冲区10M */
	final int RECEIVE_BUFFER_SIZE = 2048 * 5000;
	/** 字符编码 */
	final Charset UTF_8 = Charset.forName("UTF-8");
}